package org.redmagic.location;

import javax.annotation.Nonnull;
import javax.annotation.ParametersAreNonnullByDefault;

/**
 * A {@link LocationParser} is a generic way to take
 * an object <T> and convert it into a {@link Location}.
 * These are generally used in conjunction with a 
 * {@link LocationFactory} to return back {@link Location}'s.
 * 
 * @param <T> The object the location will be parsed from.
 */
@ParametersAreNonnullByDefault
public interface LocationParser<T> {

    @Nonnull
    Location parse(T input);
}
